<template>
	<div>
		<div class="banner" @click="handleBannerClick">
			<img class="banner-img" src="//img1.qunarzz.com/sight/p0/1704/a5/a59677101e07d38a3.img.jpg_600x330_5aa6e477.jpg"/>
			<div class="banner-info">
				<div class="banner-title">大连圣亚海洋世界</div>
				<div class="banner-number"><span class="iconfont">&#xe632;</span>39</div>
			</div>
		</div>
		<common-gallary :imgs="imgs" v-show="showGallary" @close="handleGallaryClose"></common-gallary>
	</div>
</template>

<script>
	import CommonGallary from 'common/gallary/gallary'
	export default {
		name: 'detailBanner',
		components:{
			CommonGallary
		},
		data() {
			return {
				imgs: ["http://img1.qunarzz.com/sight/p0/201404/23/04b92c99462687fa1ba45c1b5ba4ad77.jpg_800x800_70debc93.jpg", "http://img1.qunarzz.com/sight/p0/1709/76/7691528bc7d7ad3ca3.img.png_800x800_9ef05ee7.png"],
				showGallary: false
			};
		},
		methods: {
			handleBannerClick() {
				this.showGallary = true
			},
			handleGallaryClose() {
				this.showGallary = false
			}
		},
	}
</script>


<style scoped lang="stylus">
	@import '~styles/varibles.styl'
	
	.banner
		position: relative
		overflow: hidden
		height:0
		padding-bottom: 55%
		color: #fff
		.banner-img 
			width: 100%
		.banner-info
			position: absolute
			left:0
			right:0
			bottom:0
			line-height:.6rem
			display: flex
			background:linear-gradient(to bottom,rgba(0,0,0,0),rgba(0,0,0,.8))
			.banner-title
				flex:1
				font-size:.32rem
				padding-left:0.2rem
			.banner-number
				width: 1.2rem
				text-align:center
				line-height:.32rem
				height:.32rem
				margin-top:.12rem
				border-radius:.2rem
				font-size:.24rem
				padding: .04rem
				margin-right:.2rem
				background:rgba(0,0,0,0.8)

</style>

